<%--
  Created by IntelliJ IDEA.
  User: CXSM
  Date: 2023-10-07
  Time: 14:17
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<c:set var="path" value="${pageContext.request.contextPath }"/>
<html>
<head>
    <title>场次管理</title>
    <link rel="stylesheet" type="text/css" href="../../static/admin/layui/css/layui.css" />
    <link rel="stylesheet" type="text/css" href="../../static/admin/css/admin.css" />
    <style>

    </style>
</head>
<body>
<div class="wrap-container clearfix">
    <div class="column-content-detail">
        <form class="layui-form" action="">
            <div class="layui-form-item">
                <div class="layui-inline tool-btn">
                    <button class="layui-btn layui-btn-small layui-btn-normal addBtn" data-url="article-add.jsp"><i class="layui-icon">&#xe654;</i></button>
                    <button class="layui-btn layui-btn-small layui-btn-danger delBtn"  data-url="article-add.jsp"><i class="layui-icon">&#xe640;</i></button>
                    <button class="layui-btn layui-btn-small layui-btn-warm listOrderBtn hidden-xs" data-url="article-add.jsp"><i class="iconfont">&#xe656;</i></button>
                </div>
                <div class="layui-inline">
                    <input type="text" name="movieCnName" required lay-verify="required" placeholder="请输入电影中文名称" autocomplete="off" class="layui-input">
                </div>
                <div class="layui-inline">
                    <select name="movieHall" lay-filter="status">
                        <option value="">请选择影厅</option>
                        <option value="">一号影厅</option>
                        <option value="021">二号影厅</option>
                        <option value="0571">三号影厅</option>
                    </select>
                </div>
                <button class="layui-btn layui-btn-normal" lay-submit="search">搜索</button>
            </div>
        </form>
        <div class="layui-form" id="table-list">
            <table class="layui-table" lay-even lay-skin="nob">
                <colgroup>
                    <col width="65">
                    <col class="hidden-xs" width="80">
                    <col class="hidden-xs" width="130">
                    <col>
                    <col class="hidden-xs" width="150">
                    <col class="hidden-xs" width="180">
                    <col width="190">
                    <col width="150">
                </colgroup>
                <thead>
                <tr id="th_title">
                    <th><input type="checkbox" name="" lay-skin="primary" lay-filter="allChoose"></th>
                    <th class="hidden-xs">ID</th>
                    <th class="hidden-xs">影厅</th>
                    <th>电影</th>
                    <th class="hidden-xs">最终售价</th>
                    <th class="hidden-xs">场次安排</th>
                    <th class="hidden-xs">添加时间</th>
<%--                    <th>状态</th>--%>
                    <th>操作</th>
                </tr>
                </thead>
                <tbody>
                <c:set var="schedulePage" value="${sessionScope.ScheduleDataList}"></c:set>
                <c:choose>
                    <c:when test="${empty schedulePage}">
                        <script>window.location='${path}/servlet/cinemaBackJsp/selVSchedule'</script>
                    </c:when>
                    <c:otherwise>
                        <c:forEach var="schList" items="${schedulePage}" varStatus="i">
                            <tr>
                                <td><input type="checkbox" name="" lay-skin="primary" data-id="1"></td>
                                    <%--                    索引--%>
                                <td class="hidden-xs">${i.index+1}</td>
                                    <%--                    影厅--%>
                                    <%--                    <td class="hidden-xs"><input type="text" name="title" autocomplete="off" class="layui-input" value="0" data-id="1"></td>--%>
                                <td class="hidden-xs">${schList.hallName}</td>
                                    <%--                    电影名称--%>
                                <td>${sch.movieCnName}</td>
                                    <%--                    最终售价--%>
                                <td class="hidden-xs">${schList.scheduleMoney}</td>
                                    <%--                    场次安排--%>
                                <td class="hidden-xs">${schList.sessionName} ${schList.sessionTime}</td>
                                    <%--                    <td><button class="layui-btn layui-btn-mini layui-btn-normal">添加时间</button></td>--%>
                                    <%--                    影院电影安排添加时间--%>
                                <td class="hidden-xs">${schList.scheduleTime}</td>
                                <td>
                                    <div class="layui-inline">
                                        <button class="layui-btn layui-btn-small layui-btn-normal go-btn" data-id="1" data-url="article-detail.jsp"><i class="layui-icon">&#xe642;</i></button>
                                        <button class="layui-btn layui-btn-small layui-btn-danger del-btn" data-id="1" data-url="article-detail.jsp"><i class="layui-icon">&#xe640;</i></button>
                                    </div>
                                </td>
                            </tr>
                        </c:forEach>
                    </c:otherwise>
                </c:choose>
                </tbody>
            </table>
<%--            分页--%>
            <div class="page-wrap">
                <ul class="pagination">
                    <li class="disabled"><span>«</span></li>

                    <c:forEach begin="1" end="${sessionScope.totalPageCount}" step="1" var="j">
                        <li class="active"><a href="/servlet/cinemaBackJsp/selVSchedule?currPageNo="+${j}>${j}</a></li>
                    </c:forEach>

                    <li>
                        <a href="#">»</a>
                    </li>
                </ul>
            </div>
        </div>
    </div>
</div>
<script src="../../static/admin/layui/layui.js" type="text/javascript" charset="utf-8"></script>
<script src="../../static/admin/js/common.js" type="text/javascript" charset="utf-8"></script>
</body>
</html>
